package org.bbx.autoops.utils;

import java.lang.reflect.Field;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class EntityToMapUtils {

    public static Map<String , List<String>> getMap(Object o) throws IllegalAccessException {
        Map<String, List<String>> m = new HashMap<>();
        for (Field field : o.getClass().getDeclaredFields()) {
            field.setAccessible(true);
            List<String> v = (List<String>) field.get(o);
            m.put(field.getName(), v);
        }
        return m;
    }

}
